let zanReducer=(state=0,action)=>{
  switch (action.type) {
    case 'Like':
      return state + 1;
    case 'step':
      return state - 1;
  
    default:
      return state;
  }
}

export default zanReducer;

export let addZan=()=>({
  type:'Like'
})

export let minusZan=()=>({
  type:'step'
})

